Optimal. Leaf size=31 \[ \frac {x}{2 a}+\frac {\cos (c+d x) \sin (c+d x)}{2 a d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 31, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.286, Rules used = {3738, 12, 2715,
8} \begin {gather*} \frac {\sin (c+d x) \cos (c+d x)}{2 a d}+\frac {x}{2 a} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 12
Rule 2715
Rule 3738
Rubi steps
\begin {align*} \int \frac {1}{a+a \tan ^2(c+d x)} \, dx &=\int \frac {\cos ^2(c+d x)}{a} \, dx\\ &=\frac {\int \cos ^2(c+d x) \, dx}{a}\\ &=\frac {\cos (c+d x) \sin (c+d x)}{2 a d}+\frac {\int 1 \, dx}{2 a}\\ &=\frac {x}{2 a}+\frac {\cos (c+d x) \sin (c+d x)}{2 a d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 26, normalized size = 0.84 \begin {gather*} \frac {2 (c+d x)+\sin (2 (c+d x))}{4 a d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.06, size = 38, normalized size = 1.23
method | result | size |
risch | \(\frac {x}{2 a}+\frac {\sin \left (2 d x +2 c \right )}{4 a d}\) | \(25\) |
derivativedivides | \(\frac {\frac {\tan \left (d x +c \right )}{2+2 \left (\tan ^{2}\left (d x +c \right )\right )}+\frac {\arctan \left (\tan \left (d x +c \right )\right )}{2}}{d a}\) | \(38\) |
default | \(\frac {\frac {\tan \left (d x +c \right )}{2+2 \left (\tan ^{2}\left (d x +c \right )\right )}+\frac {\arctan \left (\tan \left (d x +c \right )\right )}{2}}{d a}\) | \(38\) |
norman | \(\frac {\frac {x}{2 a}+\frac {\tan \left (d x +c \right )}{2 a d}+\frac {x \left (\tan ^{2}\left (d x +c \right )\right )}{2 a}}{1+\tan ^{2}\left (d x +c \right )}\) | \(49\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.49, size = 36, normalized size = 1.16 \begin {gather*} \frac {\frac {d x + c}{a} + \frac {\tan \left (d x + c\right )}{a \tan \left (d x + c\right )^{2} + a}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 4.09, size = 40, normalized size = 1.29 \begin {gather*} \frac {d x \tan \left (d x + c\right )^{2} + d x + \tan \left (d x + c\right )}{2 \, {\left (a d \tan \left (d x + c\right )^{2} + a d\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 87 vs.
\(2 (22) = 44\).
time = 0.28, size = 87, normalized size = 2.81 \begin {gather*} \begin {cases} \frac {d x \tan ^{2}{\left (c + d x \right )}}{2 a d \tan ^{2}{\left (c + d x \right )} + 2 a d} + \frac {d x}{2 a d \tan ^{2}{\left (c + d x \right )} + 2 a d} + \frac {\tan {\left (c + d x \right )}}{2 a d \tan ^{2}{\left (c + d x \right )} + 2 a d} & \text {for}\: d \neq 0 \\\frac {x}{a \tan ^{2}{\left (c \right )} + a} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.56, size = 37, normalized size = 1.19 \begin {gather*} \frac {\frac {d x + c}{a} + \frac {\tan \left (d x + c\right )}{{\left (\tan \left (d x + c\right )^{2} + 1\right )} a}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 11.83, size = 26, normalized size = 0.84 \begin {gather*} \frac {\frac {\sin \left (2\,c+2\,d\,x\right )}{4\,a}+\frac {d\,x}{2\,a}}{d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________